home *** CD-ROM | disk | FTP | other *** search
- /***********************************************************************************
- CExpanderList.h
-
- Copyright © 1994 B-Ray Software. All rights reserved.
- Developed using Symantec C++ 7.0.2 and Symantec's TCL library.
- Portions of this code courtesy Symantec, Inc.
-
- This code may be freely distributed as long as this notice remains. This code
- may not be used in any commercial software without the consent of B-Ray Software.
-
- ---
-
- Header file for CExpanderList class.
-
- ***********************************************************************************/
- #pragma once
-
- #include "CExpander.h"
-
- class CExpanderList : public CExpander {
-
- private:
- long selectedIndex;
-
- protected:
- virtual void SelectChild( CFamily *aChild );
- virtual void ChildMessage( CFamily *aChild, long message, void *param );
- virtual void ParentMessage( long message, void *param );
-
- public:
-
- TCL_DECLARE_CLASS
-
- CExpanderList();
- CExpanderList( CView *anEnclosure, CBureaucrat *aSupervisor,
- short aWidth = 0, short aHeight = 0, short aHLoc = 0, short aVLoc = 0,
- SizingOption aHSizing = sizFIXEDSTICKY, SizingOption aVSizing = sizFIXEDSTICKY );
- virtual ~CExpanderList();
-
- /*
- * Access methods
- */
- virtual void SetSelectedIndex( long index );
- virtual long GetSelectedIndex( void )
- { return selectedIndex; };
-
- virtual void SetExpandedState( Boolean fState );
-
- virtual CFamily *PrevChild( long index )
- { return IsExpanded() ? CExpander::PrevChild( index ) : NULL; };
- virtual CFamily *NextChild( long index )
- { return IsExpanded() ? CExpander::NextChild( index ) : NULL; };
- virtual CFamily *LastChild( void )
- { return IsExpanded() ? CExpander::LastChild() : FirstChild(); };
-
- /*
- * Event methods
- */
- virtual void DoKeyDown( char theChar, Byte keyCode, EventRecord *macEvent );
- virtual void DoAutoKey( char theChar, Byte keyCode, EventRecord *macEvent )
- { DoKeyDown( theChar, keyCode, macEvent ); };
-
- /*
- * Stream methods
- */
- virtual void PutTo( CStream &stream );
- virtual void GetFrom( CStream &stream );
- };
-
-